'use strict';
module.exports = (sequelize, DataTypes) => {
  const fitment = sequelize.define('fitment', {
    zx_id: {
      allowNull: false,
      autoIncrement: true,
      primaryKey: true,
      type: DataTypes.INTEGER
    },
    user_id: {
      type: DataTypes.INTEGER
    },
    del: {
      type: DataTypes.INTEGER
    },
    text: {
      type: DataTypes.TEXT
    },
    created_at: {
      allowNull: false,
      type: DataTypes.INTEGER
    }
  }, {
    timestamps: false
  });
  fitment.associate = function(models) {
    // associations can be defined here
    fitment.belongsTo(models.user, {
      foreignKey: 'user_id'
    });

  };
  return fitment;
};